<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
      canvas {
        background-color: rgb(155, 155, 201);
        display: block;
        margin: 0 auto;
      }
    </style>
  </head>
  <body>
    <script>
      const canvas = document.createElement("canvas");
      canvas.width = 800;
      canvas.height = 600;
      document.body.append(canvas);
      const context = canvas.getContext("2d");

      // context.translate(100,100);
      // context.rotate(45 * Math.PI / 180);
      // context.fillRect(-50,-50,100,100)

      // context.scale(1.2,1.2);
      // context.fillRect(100,100,100,100)

      context.fillStyle = "hotpink";
      context.transform(1, (15 * Math.PI) / 180, 0, 1.2, 100, 50);
      context.fillRect(0, 0, 100, 100);
    </script>
  </body>
</html>
